﻿using System.Linq.Expressions;
using Basic.FormModel.DB;
using Basic.FormRemoteModel.PhyFormInter.Model;

namespace Basic.FormCollect
{
    public interface IPhysicalTableCollect
    {
        bool CheckIsNull ( long id );
        void Clear ( long formId );
        Result Get<Result> ( long id ) where Result : class, new();
        Result[] Gets<Result> ( long[] ids ) where Result : class, new();
        Result[] GetsByFormId<Result> ( long formId ) where Result : class, new();
        void Sync ( long formId, PhyFormTable[] table );
        Result[] GetsByFormId<Result> ( long formId, Expression<Func<DBPhysicalTable, Result>> selector ) where Result : class, new();
    }
}